package com.z.common.pro.controller;

import com.z.common.web.base.BaseController;
import lombok.extern.slf4j.Slf4j;
import org.camunda.bpm.engine.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.servlet.ModelAndView;

@RestController
@RequestMapping("process/history")
@Slf4j
public class ProHistoryController extends BaseController {

    private final String prefix = "system/process/history";

    @Autowired
    private RuntimeService runtimeService;
    @Autowired
    private TaskService taskService;
    @Autowired
    private HistoryService historyService;
    @Autowired
    private RepositoryService repositoryService;

    @Autowired
    private IdentityService identityService;

    /**
     * 流程图查看页面
     * @return
     */
    @GetMapping("/main")
    public ModelAndView main(Model model, String id) {
        model.addAttribute("id", id);
        return jumpPage(prefix + "/main");
    }

}
